<template>
	<view class="page-sbody">
		<view class="main">
			<u-icon name="checkmark-circle-fill" color="#11ce1f" size="220"></u-icon>
			<view class="title">{{title}}</view>
			<view class="sub-title">{{subTitle}}</view>
			<u-button type="error" shape="circle" :plain="true" class="btn" @click="openPage">{{btnValue}}</u-button>
		</view>
	</view>
</template>
<script>
export default{
	name:"MySuccess",
	data() {
		return {
			title: '',
			subTitle: '',
			btnValue: '',
			url: ''
		}
	},
	onLoad(option) {
		//获取路由参数
	    this.title = option.title ? option.title : '成功!';
		this.subTitle = option.subTitle ? option.subTitle : '';
		this.btnValue = option.btnValue ? option.btnValue : '返回';
		this.url = option.url ? option.url : '/index/index';
	},
	methods:{
		// 跳转页面
		openPage(){
			this.$utils.reLaunch(this.url);
		}
	}
}
</script>

<style lang="scss" scoped>
.main{
	width:75%;
	margin:150rpx auto 0;
	text-align: center;
	.title{
		margin-top:10rpx;
		font-size:34rpx;
	}
	.sub-title{
		margin-top:15rpx;
		font-size:24rpx;
		color:#aaa;
	}
	.btn{
		margin-top:80rpx;
		color: #dd1010 !important;
		border-color: #B00E0E !important;
	}
}
</style>